<template>
  <view class="container">
    <!-- 顶部组件 -->
    <u-navbar
      :is-back="true"
      :background="{ background: '#fff' }"
      :border-bottom="false"
      id="nav-bar"
      title="入账明细"
    ></u-navbar>
    <!-- 列表 -->
    <!-- <mescroll-body
          ref="mescrollRef"
          @init="mescrollInit"
          top="0"
          @down="downCallback"
          :up="upOption"
          @up="upCallback"
        > -->

    <view class="list">
      <view class="date">
        <text>2024-05-06</text>
        <image
          class="icon"
          src="/static/images/icon-tzgg.png"
          mode="widthFix"
        ></image
      ></view>
      <view class="item">
        <view class="row">
          <view class="title">
            <image
              class="icon"
              src="/static/images/icon-zzsq.png"
              mode="widthFix"
            ></image>
            <text>分红钱包入账</text>
          </view>
          <view class="num">+0</view>
        </view>
        <view class="row">
          <view class="pre">入账前余额：1542.78</view>
          <view class="after">入账后余额：1542.78</view>
        </view>
      </view>
    </view>
    <!-- </mescroll-body> -->
  </view>
</template>
<script>
import MescrollMixin from '@/components/mescroll-uni/mescroll-mixins.js';
import service from '@/common/service';
import util from '@/common/utils';

export default {
  mixins: [MescrollMixin],
  data() {
    return {
      upOption: {
        page: {
          num: 0,
          size: 10,
        },
        noMoreSize: 5,
        empty: {
          icon: '/static/images/icon-empty.png',
          tip: '',
        },
      },
      mescroll: null,
    };
  },
  onLoad(e) {},
  methods: {
    mescrollInit(mescroll) {
      this.mescroll = mescroll;
    },
    downCallback() {
      this.recordList = [];
      this.mescroll.resetUpScroll();
    },
    upCallback(page) {
      this.getTradePage(page);
    },
    getData(page) {
      const that = this;
      const param = {
        pageNumber: page.num,
        pageSize: page.size,
      };
      //   service.getTradePage(
      //     param,
      //     function (res) {
      //       if (res && res.data) {
      //         that.mescroll.endSuccess(res.data.data.length);
      //         if (page.num == 1) that.recordList = [];
      //         that.recordList = that.recordList.concat(res.data.data);
      //       }
      //     },
      //     function (res) {}
      //   );
    },
  },
};
</script>

<style lang="scss" scoped>
page {
  background-color: #f5f5f5;
}

.container {
  width: 100%;
  min-height: 100vh;
  padding: 0;
  text-align: center;
  background-color: #f5f5f5;
}

.list {
  width: 100%;
  padding: 30rpx;
  .date {
    position: relative;
    margin-bottom: 30rpx;
    width: 100%;
    font-weight: bold;
    font-size: 28rpx;
    color: #333333;
    line-height: 32rpx;
    width: 100%;
    text-align: left;
    text {
      position: relative;
      z-index: 9;
    }
    .icon {
      position: absolute;
      top: -10rpx;
      left: 145rpx;
      width: 32rpx;
      height: 32rpx;
      border-radius: 50%;
      z-index: 1;
    }
  }
  .item {
    position: relative;
    width: 100%;
    height: auto;
    padding: 30rpx;
    background: #ffffff;
    border-radius: 16rpx;
    .row {
      display: flex;
      justify-content: space-between;
      align-items: center;
      width: 100%;
    }
    .title {
      display: flex;
      align-items: center;
      .icon {
        width: 32rpx;
        height: 32rpx;
      }
      text {
        margin-left: 10rpx;
        font-weight: 800;
        font-size: 28rpx;
        color: #333333;
      }
    }
    .num {
      font-weight: 800;
      font-size: 28rpx;
      color: #f03434;
    }
    .pre {
      margin-top: 20rpx;
      font-weight: 400;
      font-size: 24rpx;
      color: #999999;
    }
    .after {
      margin-top: 20rpx;
      font-weight: 400;
      font-size: 24rpx;
      color: #999999;
    }
  }
}
</style>
